package com.forever7776.life.core.entity.sys;

import java.util.Date;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;

/**
 * <p>
 * 平台用户表
 * </p>
 *
 * @author kz
 * @since 2018-02-09
 */
@TableName("sys_user")
public class SysUser extends Model<SysUser> {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.UUID)
    private String id;
    /**
     * 用户名(登录名,如jack)
     */
    private String username;
    /**
     * 密码(明文)
     */
    private String password;
    /**
     * 密码（加密）
     */
    private String salt;
    /**
     * 头像
     */
    private String headimg;
    /**
     * 昵称
     */
    private String nickname;
    /**
     * 用户真实姓名
     */
    private String name;
    /**
     * 邮箱
     */
    private String email;
    /**
     * 手机
     */
    private String phone;
    /**
     * 公司名称
     */
    private String company;
    /**
     * 职位
     */
    private String job;
    /**
     * 微信
     */
    private String wx;
    /**
     * 微信二维码加好友，图片地址
     */
    @TableField("wx_qrcode")
    private String wxQrcode;
    /**
     * qq
     */
    private String qq;
    /**
     * 性别（0：保密 1：男 2：女）
     */
    private Integer sex;
    /**
     * 自我简介
     */
    @TableField("self_info")
    private String selfInfo;
    /**
     * 最后登录时间
     */
    @TableField("login_time")
    private Date loginTime;
    /**
     * 登出时间(手动登出,系统登出即session超时时间)
     */
    @TableField("logout_time")
    private Date logoutTime;
    /**
     * 创建时间
     */
    @TableField("insert_date")
    private Date insertDate;
    /**
     * 更新时间
     */
    @TableField("last_update")
    private Date lastUpdate;
    /**
     * 冻结：-1 正常:0 封号：1  手动注销：2  系统销毁：3
     */
    private Integer status;


    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt;
    }

    public String getHeadimg() {
        return headimg;
    }

    public void setHeadimg(String headimg) {
        this.headimg = headimg;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getCompany() {
        return company;
    }

    public void setCompany(String company) {
        this.company = company;
    }

    public String getJob() {
        return job;
    }

    public void setJob(String job) {
        this.job = job;
    }

    public String getWx() {
        return wx;
    }

    public void setWx(String wx) {
        this.wx = wx;
    }

    public String getWxQrcode() {
        return wxQrcode;
    }

    public void setWxQrcode(String wxQrcode) {
        this.wxQrcode = wxQrcode;
    }

    public String getQq() {
        return qq;
    }

    public void setQq(String qq) {
        this.qq = qq;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }

    public String getSelfInfo() {
        return selfInfo;
    }

    public void setSelfInfo(String selfInfo) {
        this.selfInfo = selfInfo;
    }

    public Date getLoginTime() {
        return loginTime;
    }

    public void setLoginTime(Date loginTime) {
        this.loginTime = loginTime;
    }

    public Date getLogoutTime() {
        return logoutTime;
    }

    public void setLogoutTime(Date logoutTime) {
        this.logoutTime = logoutTime;
    }

    public Date getInsertDate() {
        return insertDate;
    }

    public void setInsertDate(Date insertDate) {
        this.insertDate = insertDate;
    }

    public Date getLastUpdate() {
        return lastUpdate;
    }

    public void setLastUpdate(Date lastUpdate) {
        this.lastUpdate = lastUpdate;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "SysUser{" +
                "id='" + id + '\'' +
                ", username='" + username + '\'' +
                ", password='" + password + '\'' +
                ", salt='" + salt + '\'' +
                ", headimg='" + headimg + '\'' +
                ", nickname='" + nickname + '\'' +
                ", name='" + name + '\'' +
                ", email='" + email + '\'' +
                ", phone='" + phone + '\'' +
                ", company='" + company + '\'' +
                ", job='" + job + '\'' +
                ", wx='" + wx + '\'' +
                ", wxQrcode='" + wxQrcode + '\'' +
                ", qq='" + qq + '\'' +
                ", sex=" + sex +
                ", selfInfo='" + selfInfo + '\'' +
                ", loginTime=" + loginTime +
                ", logoutTime=" + logoutTime +
                ", insertDate=" + insertDate +
                ", lastUpdate=" + lastUpdate +
                ", status=" + status +
                '}';
    }
}
